import request from "@/utils/request";

// 列表获取接口
export const getCardInfo = (params) => request.get("/essay/list", params);

//搜索接口
export const getSearchInfo = (params) => request.post("/essay/search", params);

// 获取文章详情
export const getArticleDetail = (id) => request.post("/essay/detail", null, {
    params: { id }
});

//获取ai面试问题
export const getVoiceText = (data) => {
  return request({
      url: '/api/dify/generate',
      method: 'get',
      params: {
          text: data.text,
      }
  });
}